import http from "../index";

// 添加
export const getUserListApi = async (data) =>
  await http.post("user/search/list", data);

export const insertUserApi = async (data) =>
  await http.post("user/insert", data);

export const updateUserApi = async (data) =>
  await http.post("user/update", data);

export const enableUserApi = async (data) =>
  await http.post("user/enable", data);

export const getUserDetailApi = async (id) => await http.get(`user/${id}`);

export const getUserInfoApi = async () => await http.get(`user/details`);

export const deleteUserApi = async (id) => await http.post(`user/delete/${id}`);
export const resetUserApi = async (data) =>
  await http.post(`user/reset/pwd`, data);

export const changeUserPwdApi = async (data) =>
  await http.post(`user/change/pwd`, data);
